// ============================== 导入依赖 ============================== //

import CORE from '@/CORE'
import Client from '@api/user/api/SysRegionApi'

import ComClass from '@api/ComQuery'
import ListClass from '@api/user/model/SysRegionDto'

const CLIENT = CORE.grpcCLIENT(Client)
const COM = [ComClass, 'comQuery']

// ============================== 导出远程接口 ============================== //

export default {
  // —————————————————————————————— 下拉框 —————————————————————————————— //

  async getSelect(selectParam, TIP = '查询配电室下拉框') {
    const DTO = CORE.grpcDTO(ListClass, selectParam, COM)
    const resp = await CORE.grpc(TIP, CLIENT, 'sysRegionList', DTO)
    return resp.content || []
  },
}
